home *** CD-ROM | disk | FTP | other *** search
- // %filename% -- dialog
- // Created %date% %time% by AppMaker
-
- #include "U%dlogname%.h"
- #ifndef __TYPES__
- #include <Types.h>
- #endif
- #ifndef __PACKAGES__
- #include <Packages.h>
- #endif
- #include "ResourceDefs.h"
-
- %for each item gen itemNr%
-
- %for each item gen classMethods%
- #pragma segment ARes
- /*----------*/
- pascal void T%dlogname%::DoChoice (TView *origView,
- short itsChoice)
- {
- long origID;
-
- origID = (long) (origView->fIdentifier);
- switch (origID) {
- %for each item gen doChoice%
-
- } /* switch */
-
- %if modalOneShot%
- DismissDialog (origID);
- %else%
- inherited::DoChoice (origView, itsChoice);
- %endif%
- } /* DoChoice */
-
- #if qInspector
- #pragma segment AFields
- /*----------*/
- pascal void T%dlogname%::Fields (
- pascal void (*DoToField)
- (StringPtr fieldName,
- Ptr fieldAddr,
- short fieldType,
- void *DoToField_StaticLink),
- void *DoToField_StaticLink)
- {
- (*DoToField) ("\pT%dlogname%", NULL, bClass, DoToField_StaticLink);
- inherited::Fields (DoToField, DoToField_StaticLink);
- } /* Fields */
-
- #endif
- %if modeless%
- #pragma segment AOpen
- /*----------*/
- TWindow *New%dlogname% (void)
- {
- TWindow *theWindow;
- TObject *dummy;
-
- theWindow = NewTemplateWindow (k%dlogname%ID, NULL);
- // initialize subviews from current settings
-
- if (gDeadStripSuppression) {
- dummy = new T%dlogname%;
- %for each item gen gDeadStripSuppression%
-
- }
- return (theWindow);
- } /*New%dlogname%*/
- %else%
- #pragma segment ASelCommand
- /*----------*/
- void Do%dlogname% (void)
- {
- TWindow *aWindow;
- TObject *dummy;
- TDialogView *aDialogView;
- ResType dismisser;
-
- aWindow = NewTemplateWindow (k%dlogname%ID, NULL);
- // initialize subviews from current settings
- aDialogView = (TDialogView *)(aWindow->FindSubView ('dlog'));
- dismisser = aDialogView->PoseModally ();
- if (dismisser != aDialogView->fCancelItem) {
- // use new settings from subviews
- }
- aWindow->Close ();
-
- if (gDeadStripSuppression) {
- dummy = new T%dlogname%;
- %for each item gen gDeadStripSuppression%
-
- }
- } /* Do%dlogname% */
-
- /* U%dlogname% */
-